{% extends '::backend.html.twig' %}

{% block contenido-%}
{% if is_granted('ROLE_ADMINISTRADOR') %}
<div class="container">
<h3>Editar Cliente</h3>
			<form method="post" action="{{ path('administracion_customer_update',{'id':entity.id}) }}">
	<input type="hidden" name="_method" value="PUT" />
	<div class="col-md-4 col-md-offset-0">
		<div class="row form-group">
				{{ form_row(edit_form.name) }}
				{{ form_errors(edit_form.name) }}
		</div>
		<div class="row form-group">
				{{ form_row(edit_form.phone) }}
				{{ form_errors(edit_form.phone) }}
	</div>
	<div class="row form-group">
				{{ form_row(edit_form.email) }}
				{{ form_errors(edit_form.email) }}
	</div>
	<div class="row form-group">
				{{ form_row(edit_form.province) }}
				{{ form_errors(edit_form.province) }}
	</div>
</div>	
<div class="col-md-4 col-md-offset-1">
		<div class="row form-group">
				{{ form_row(edit_form.city) }}
				{{ form_errors(edit_form.city) }}
		</div>
		<div class="row form-group">
				{{ form_row(edit_form.zipcode) }}
				{{ form_errors(edit_form.zipcode) }}
	</div>
	<div class="row form-group">
				{{ form_row(edit_form.address) }}
				{{ form_errors(edit_form.address) }}
	</div>
	<div class="row form-group">
				{{ form_row(edit_form.dni) }}
				{{ form_errors(edit_form.dni) }}
				{{ form_rest(edit_form) }}
	</div>
	<div class="row form-group">

				{{ form_row(edit_form.submit) }}
    <a class="btn btn-xs btn-link" href="{{ path('administracion_customer') }}">
											Listar Clientes
        </a>
	</div>
</form>
    {{ form(delete_form) }}
</div>
	<div class="row">
	</div>
</div>
{% else %}
<p>Usted no tiene permisos para acceder a este area</p>
{% endif %}
{% endblock %}
